package com.yanqu.backendweb.bean.enums;

import com.yanqu.backendweb.service.AbsService;
import com.yanqu.backendweb.service.impl.*;
import com.yanqu.road.entity.enums.ConvertibleEnum;

/**
 * @author duli
 * @version 1.0
 * @date 2020/10/14 15:06
 * @Description 玩家其它信息类型
 */
public enum eRoleOtherInfoType implements ConvertibleEnum<Integer> {

    /*UNION_INFO(0,"商会信息", UnionInfoServiceImpl.class),

    REGISTERED_INFO(1,"注册信息", RoleInfoServiceImpl.class),

    PLAYER_INFO(2,"玩家",UnionInfoServiceImpl.class),*/

    CHILD_SYSTEM(0,"子嗣系统", ChildServiceImpl.class),

    BEAUTY_SYSTEM(1,"美女系统", BeautyServiceImpl.class),

    BEAUTY_SKIN(2,"美女皮肤", BeautySkinServiceImpl.class),

    PATRONS(3,"门客系统", PatronsServiceImpl.class),

    VEHICLE_SYSTEM(4,"珍兽系统",VehicleServiceImpl.class),

    BUILDING_SYSTEM(5,"商铺系统",BuildingServiceImpl.class),

    CHARITABLE_SYSTEM(6,"行善系统",CharitableServiceImpl.class),

    MARRIAGE_SYSTEM(7,"亲家系统",MarriageServiceImpl.class),

    AVATAR_FRAME_SYSTEM(8,"头像框系统",DecorationServiceImpl.class),

    TITLE_SYSTEM(9,"称号系统",DecorationServiceImpl.class),

    BAG_PROPS(10,"背包道具",GamePropsBagServiceImpl.class),
    ;

    private int intValue;
    private String name;
    private Class<? extends AbsService> service;

    public Class<? extends AbsService> getService() {
        return service;
    }

    eRoleOtherInfoType(int value, String name,Class<? extends AbsService> service) {
        intValue = value;
        this.name=name;
        this.service=service;
    }
    @Override
    public Integer getIntValue() {
        return intValue;
    }

    @Override
    public String getName() {
        return name;
    }

    public static eRoleOtherInfoType forValue(int value) {
        for (eRoleOtherInfoType type : eRoleOtherInfoType.values()) {
            if (type.intValue == value) {
                return type;
            }
        }
        return null;
    }
}
